import React, {useState} from 'react'
export default function DemoPage(){
    const [nav,setNav]=useState(0);
    window.navigator.geolocation.getCurrentPosition(function(res){
        console.log(res)
        setNav(res);
    })
    return (
        <div>DemoPage
            <span>{nav}</span>
        </div>
    )
}